<%@ page language="java" import="java.util.*, com.heo.web.util.BackAES, com.heo.web.util.Constants, com.heo.web.util.Utils" pageEncoding="UTF-8"%>
<%-- <%@ include file="/taglibs.jsp"%> --%>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title></title>
<meta name="viewport" content="width=640,user-scalable=no" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="white" />
<link rel="stylesheet" href="css/share.css" />
<script src="js/share.js" type="text/javascript"></script>
<%
	String mid = request.getParameter("M_ID");
	String invitationCode = request.getParameter("CODE");
	String ip = request.getServerName() + ":" + request.getServerPort();
	
	String paramsss = request.getQueryString();
	String params = BackAES.decrypt(paramsss, Constants.AES_SKEY);
	long washerId = 0l;
	String macAddress = "";
	if (Utils.checkNull(params)) {
		String[] param = params.split("&");
		washerId = Utils.getLong(param[0].substring(param[0].indexOf("=") + 1));
		macAddress = param[1].substring(param[1].indexOf("=") + 1);
			if(washerId > 0){
			String redirectUrl = Constants.XIAOZHANG_URL + macAddress+"/kaola";
			System.out.println(redirectUrl);
			response.sendRedirect(redirectUrl);
			return;
		}
	}else{
		response.sendRedirect("http://8zao.net");
	}
%>
</html>
